1. Field of the Invention
The present invention relates to an optical disk apparatus for writing data to an optical disk or reading data written thereon.
2. Description of the Related Art
In a conventional optical disk apparatus for writing data to an optical disk or reading data written thereon, write back process is performed by use of a cache memory in order to improve the speed of writing data to the optical disk apparatus.
The write back processing is performed in accordance with the following steps.
More specifically, write data received from the host computer is stored in a data buffer memory. At the time when the storage of write data is ended, a normal end of the write back processing is indicated to the host computer. Then, write data, which is stored in data buffer memory during a vacant time when no communication with the host computer is performed, is written to the optical disk. As a result, efficient writing can be performed without having to take into consideration the relationship between write timing and data transfer timing.
If an abnormality occurs in the write back processing, it is informed that the previous write command processing is abnormally ended at the time of receiving a command from a next host computer. However, since the host computer once received the signal of the normal end, there is a case in which previous write data is not left and no data exists therein.
Therefore, in a case where an abnormality occurs in the write back processing, no previous write data is maintained in the host computer even if the occurrence of an abnormality is informed to the host computer. Moreover, write data cannot be left in the optical disk. Due to this, there is a problem in that write data is lost.